{% import "macros.html" as macros %}
{% import "user_profile/macros.html" as user_profile_macros %}
<div class="accordian">
	<ul>
	  <li>
	    <input type="checkbox" checked="">
	    <i></i>
		<a name="tags"></a>
	    {% spaceless %}
	        <h2 
	        style="font-size: 1.4em; margin-bottom: 0.5em; margin-top: 0; line-height: 1.2em;"
    		>{% trans counter=user_tags|length %}Tag ({{counter}}){% pluralize %}Tags ({{counter}}){% endtrans %}</h2>
	    {% endspaceless %}
	    <div class="user-stats-table">
	        {% for tag in user_tags %}
	            {{ macros.tag_widget(
	                tag.name,
	                html_tag = 'div',
	                search_state = search_state,
	                truncate_long_tag = True,
	                extra_content = 
	                    '<span class="tag-number" style="display: none">&#215; ' ~
	                    tag.user_tag_usage_count|intcomma ~
	                    '</span>'
	               )
	            }}
	        {% endfor %}
	        <div class="clearfix"></div>
	    </div>
	    {% if interesting_tag_names %}
	        {{ user_profile_macros.tag_selection(interesting_tag_names, 'interesting') }}
	    {% endif %}
	    {% if ignored_tag_names %}
	        {{ user_profile_macros.tag_selection(ignored_tag_names, 'ignored') }}
	    {% endif %}
	    {% if subscribed_tag_names %}
	        {{ user_profile_macros.tag_selection(subscribed_tag_names, 'subscribed') }}
	    {% endif %}
	  </li>
	  <li>
	    <input type="checkbox" checked="">
	    <i class="badges"></i>
	    {% if settings.BADGES_MODE == 'public' %}
	    <a name="badges"></a>
	    {% spaceless %}
	    <h2 style="font-size: 1.4em; margin-top: 0;">{% trans counter=total_badges %}Badge ({{counter}}){% pluralize %}Badges ({{counter}}){% endtrans %}</h2>
	    {% endspaceless %}
	    <div class="user-stats-table badges">
	        {% for badge, badge_user_awards in badges %}
	            <a
	                href="{{badge.get_absolute_url()}}"
	                title="{% trans description=badge.get_description() %}{{description}}{% endtrans %}"
	                class="medal {{ badge.get_css_class() }}"
	                style="text-decoration: none"
	            >{% trans name=badge.get_name() %}{{name}}{% endtrans %}
	            </a>
	            <ul id="badge-context-{{ badge.id }}" class="badge-context-list" style="display:none">
	                {% for award in badge_user_awards %}
	                    {% if award.content_object and award.content_object_is_post %}
	                    <li>
	                        <a
	                            href="{{ award.content_object.get_absolute_url() }}"
	                        >{% if award.content_type.post_type == 'answer' %}{% trans %}Answer to:{% endtrans %}{% endif %} {{ award.content_object.thread.title|escape }}</a>
	                    </li>
	                    {% endif %}
	                {% endfor %}
	            </ul>
	            {% if loop.index is divisibleby 3 %}
	                <br/>
	            {% endif %}
	        {% endfor %}
	    </div>
	    {% endif %}
	  </li>
	</ul>
</div>